import common from './public.js'
$(function () {
	window.history.replaceState(null, null, window.location.href);
	$("#nav-login-out").click(function(){
		window.location.href = common.baseUrl;
	})
	$("#nav-logo").click(function(){
		console.log("到logo");
		common.diyForm(common.baseUrl + "/user/oneself.do", "POST", {})
	})
	$("#nav-department").click(function(){
		console.log("到department");
		// common.diyForm(common.baseUrl + "/department/list.do", "POST", {
		// 	pageNow: 1,
		// 	pageSize: 5
		// })
		window.location.href = common.baseUrl + "/department/list.do?pageNow=1&pageSize=5&fuzzyQuery=";
	})
	$("#nav-user").click(function(){
		console.log("到user");
		// common.diyForm(common.baseUrl + "/department/list.do", "POST", {
		// 	pageNow: 1,
		// 	pageSize: 5
		// })
		window.location.href = common.baseUrl + "/user/list.do?pageNow=1&pageSize=5&fuzzyQuery=&department=0";
	})
	$("#nav-task").click(function(){
		console.log("到task");
		window.location.href = common.baseUrl + "/task/list.do";
	})
})